<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:p="http://primefaces.org/ui">

<body>

	<h:form enctype="multipart/form-data">
	
	<p:dialog header="Adicionar Imagem:" widgetVar="imagemAdd" modal="true" width="800" height="450">
		
		<h:messages></h:messages>
		<p:selectOneRadio id="options" value="#{estabelecimentoMB.radioButton}" disabled="true">  
            <f:selectItem itemLabel="Imagem" itemValue="1" />  
            <f:selectItem itemLabel="Video"  itemValue="2" />  
        </p:selectOneRadio>  
        <br />
        
		<p:fileUpload 
			fileUploadListener="#{estabelecimentoMB.inserirImagem}"
			mode="advanced" update="messages" multiple="true"
			allowTypes="/(\.|\/)(gif|jpe?g|png)$/" />

		<p:growl id="messages" showDetail="true" />
	
	</p:dialog>
	</h:form>

</body>
</html>